package com.leadingsoft.pwxk.converter;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.leadingsoft.common.converter.AbstractConverter;
import com.leadingsoft.pwxk.dto.ZlssDto;
import com.leadingsoft.pwxk.model.Zlss;

/**
 * @author: lipan 2018年5月15日
 * @description: ()
 * 
 */

@Component
public class ZlssConverter extends AbstractConverter<Zlss, ZlssDto> {

	@Autowired
	private ZlsstableConverter zlsstableConverter;

	@Override
	protected ZlssDto toDtoActual(Zlss model) {

		ZlssDto dto = new ZlssDto();
		dto.setId(model.getId());
		dto.setDataid(model.getDataid());
		dto.setDevicename(model.getDevicename());
		dto.setHyname(model.getHyname());
		dto.setTechnicscode(model.getTechnicscode());
		dto.setTechnicsname(model.getTechnicsname());
		dto.setXkdevicecode(model.getXkdevicecode());
		dto.setXktechnicscodenum(model.getXktechnicscodenum());
		dto.setZlsstable(zlsstableConverter.toDto(model.getZlsstable()));
		return dto;
	}

	@Override
	public void copyProperties(Zlss model, ZlssDto dto) {

	}

}
